import request from '@/config/axios'
import type { CmsConfig } from './types'
// 查询系统配置
export const getConfig = async () => {
  return await request.get({ url: '/cms/global-config/get' })
}
export const updateConfigApi = async (data: CmsConfig) => {
  return await request.post({ url: '/cms/global-config/update', data })
}

// 查询模板配置列表
export const getStoreTplConfigs = async () => {
  return await request.get({ url: '/infra/file-config/getStoreTplConfigs' })
}
//查询存储配置
export const getStoreConfigs = async () => {
  return await request.get({ url: '/infra/file-config/getStoreConfigs' })
}
export const getLicense = async () => {
  return await request.get({ url: '/cms/license/get' })
}

// 查询运行时内存 cpu jvm信息
export const getRealTimeSysInfo = async () => {
  return await request.get({ url: '/cms/sysinfo/getRealTimeSysInfo' })
}
// 查询磁盘等信息
export const getSysInfo = async () => {
  return await request.get({ url: '/cms/sysinfo/get' })
}
